/*
 * Copyright (c) 田梓萱 2021-2022.
 * All Rights Reserved.
 * All codes are protected by China's regulations on the protection of computer software, and infringement must be investigated.
 * 版权所有 (c) 田梓萱 2021-2022.
 * 所有代码均受中国《计算机软件保护条例》保护，本项目已获得软著.
 */

package com.xcl.calculator;

import ohos.aafwk.ability.Ability;
import ohos.hiviewdfx.HiLog;
import ohos.hiviewdfx.HiLogLabel;

/**
 * The type X log.
 *
 * @author Xcl
 * @date 2022 /1/24
 * @package com.xcl.calculator.Log
 */
public class XLog extends Ability {
    /**
     * The constant pd_pd.
     */
    public static int pd_pd;

    /**
     * Info.
     *
     * @param label   the label
     * @param message the message
     */
    public static void info(HiLogLabel label, String message) {
        if (pd_pd == 555) HiLog.info(label, "信息:[" + message + "]");
    }

    /**
     * Warn.
     *
     * @param label   the label
     * @param message the message
     */
    public static void warn(HiLogLabel label, String message) {
        if (pd_pd == 555) HiLog.warn(label, "警告:[" + message + "]");
    }

    /**
     * Error.
     *
     * @param label   the label
     * @param message the message
     */
    public static void error(HiLogLabel label, String message) {
        if (pd_pd == 555) HiLog.error(label, "错误:[" + message + "]");
    }
}
